# cython: language_level=3
from datetime import datetime

from sqlalchemy import Column, Integer, String, DateTime

from common.database import BaseTable


class Operator(BaseTable):
    __tablename__ = "operator"
    credit_code = Column(String(100), comment="企业信用状态码")
    user_name = Column(String(100), comment="负荷聚合商中文名称")
    annual_electricity_consumption = Column(
        Integer, comment="年度用电量，单位万度"
    )
    electricity_consumption_char = Column(
        String(100), comment="用电性质"
    )
    operator = Column(String(100), comment="企业联系人")
    operator_tel1 = Column(String(50), comment="联系电话")
    operator_tel2 = Column(String(50), comment="联系电话2")
    operator_address = Column(String(255), comment="注册地址")
    operator_remark = Column(String(255), comment="描述")
    create_time = Column(
        DateTime, comment="创建时间", default=datetime.now()
    )
